﻿using Basic.FlowGatewayModule.Interface;
using RpcStore.RemoteModel.ServerBind.Model;
using WeDonekRpc.ApiGateway.Attr;
using WeDonekRpc.HttpApiGateway;
using WeDonekRpc.Model;

namespace Basic.FlowGatewayModule.Api
{
    [ApiRouteName("/flow/server/group/{name}")]
    internal class ServerGroupApi : ApiController
    {
        private readonly IServerGroupService _Service;

        public ServerGroupApi ( IServerGroupService service )
        {
            this._Service = service;
        }
        public ServerItemDto[] GetServers ()
        {
            return this._Service.GetServers(RpcServerType.后台服务);
        }
        public BindServerGroupType[] Gets ()
        {
            return this._Service.Gets(RpcServerType.后台服务);
        }
    }
}
